import request from "@/utils/request"

export function list(params){
    return request({
        url:'/user/list',
        method:'get',
        params:{
            pageNum:params.pageNum,
            pageSize:params.pageSize,
            search:params.search
        }
    })
}

export function add(data){
    return request({
        url:'/user/add',
        method:'post',
        data
    })
}

export function del(id){
    return request({
        url:`/user/del/${id}`,
        method:'delete'
    })
}

export function update(data){
    return request({
        url:'/user/update',
        method:'put',
        data
    })
}